package com.bp.system.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.bp.common.annotation.Excel;
import com.bp.common.core.domain.BaseEntity;

import java.util.ArrayList;
import java.util.List;

/**
 * 用户目录对象 sys_file_index
 *
 * @author shaominjie
 * @date 2021-01-13
 */
public class SysFileIndex extends BaseEntity{
    private static final long serialVersionUID = 1L;
    /** 唯一主键 */
    private Long indexId;

    /** 上级目录编号 */
    @Excel(name = "上级目录编号")
    private Long parentId;

    /** 祖级列表 */
    @Excel(name = "祖级列表")
    private String ancestors;

    /** 文件归属类型 */
    @Excel(name = "文件归属类型")
    private Integer userType;

    /** 用户编号 */
    @Excel(name = "用户编号")
    private Long userId;

    /** 区域编号 */
    @Excel(name = "区域编号")
    private Long regionId;

    /** 部门编号 */
    @Excel(name = "部门编号")
    private Long deptId;

    /** 目录名称 */
    @Excel(name = "目录名称")
    private String indexName;

    /** 目录描述 */
    @Excel(name = "目录描述")
    private String indexDesc;

    /** 目录路径 */
    @Excel(name = "目录路径")
    private String filePath;

    /** 状态（0正常 1停用） */
    @Excel(name = "状态", readConverterExp = "0=正常,1=停用")
    private Integer status;

    /** 删除标志（0代表存在 2代表删除） */
    private Integer delFlag;

    /** 默认类型（0不可删除 1可删除） */
    @Excel(name = "默认类型", readConverterExp = "0=不可删除,1=可删除")
    private Integer systemFlag;

    /** 私有类型（0公开 1私有） */
    @Excel(name = "私有类型", readConverterExp = "0=公开,1=私有")
    private Integer selfFlag;

    /** 显示顺序 */
    @Excel(name = "显示顺序")
    private Integer orderNum;

    /** 子部门 */
    private List<SysFileIndex> children = new ArrayList<SysFileIndex>();


    public void setIndexId(Long indexId) {
        this.indexId = indexId;
    }

    public Long getIndexId(){
        return indexId;
    }
    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }

    public Long getParentId(){
        return parentId;
    }
    public void setAncestors(String ancestors) {
        this.ancestors = ancestors;
    }

    public String getAncestors(){
        return ancestors;
    }
    public void setUserType(Integer userType) {
        this.userType = userType;
    }

    public Integer getUserType(){
        return userType;
    }
    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getUserId(){
        return userId;
    }
    public void setRegionId(Long regionId) {
        this.regionId = regionId;
    }

    public Long getRegionId(){
        return regionId;
    }
    public void setDeptId(Long deptId) {
        this.deptId = deptId;
    }

    public Long getDeptId(){
        return deptId;
    }
    public void setIndexName(String indexName) {
        this.indexName = indexName;
    }

    public String getIndexName(){
        return indexName;
    }
    public void setIndexDesc(String indexDesc) {
        this.indexDesc = indexDesc;
    }

    public String getIndexDesc(){
        return indexDesc;
    }
    public void setFilePath(String filePath) {
        this.filePath = filePath;
    }

    public String getFilePath(){
        return filePath;
    }
    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getStatus(){
        return status;
    }
    public void setSystemFlag(Integer systemFlag) {
        this.systemFlag = systemFlag;
    }

    public Integer getSystemFlag(){
        return systemFlag;
    }
    public void setSelfFlag(Integer selfFlag) {
        this.selfFlag = selfFlag;
    }

    public Integer getSelfFlag(){
        return selfFlag;
    }
    public void setOrderNum(Integer orderNum) {
        this.orderNum = orderNum;
    }

    public Integer getOrderNum(){
        return orderNum;
    }

    public List<SysFileIndex> getChildren() {
        return children;
    }

    public void setChildren(List<SysFileIndex> children) {
        this.children = children;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("indexId", getIndexId())
                .append("parentId", getParentId())
                .append("ancestors", getAncestors())
                .append("userType", getUserType())
                .append("userId", getUserId())
                .append("regionId", getRegionId())
                .append("deptId", getDeptId())
                .append("indexName", getIndexName())
                .append("indexDesc", getIndexDesc())
                .append("filePath", getFilePath())
                .append("status", getStatus())
                .append("delFlag", getDelFlag())
                .append("systemFlag", getSystemFlag())
                .append("selfFlag", getSelfFlag())
                .append("orderNum", getOrderNum())
                .append("createTime", getCreateTime())
                .append("updateTime", getUpdateTime())
                .append("remark", getRemark())
                .toString();
    }
}